package com.hwua.view;

import com.hwua.util.InputTools;

/**
 * 登录界面
 * @author Administrator
 */
public class WelcomeView extends View {

    public static final int LOGIN = 1;
    public static final int REGISTER = 2;
    public static final int EXITS = 3;


    @Override
    public View showView() {
        System.out.println("1.Login");
        System.out.println("2.Register");
        System.out.println("--------------");
        System.out.println("Enter Choose:");
        InputTools it = new InputTools();
        int choose = it.checkIntInput(1,3);
        switch (choose){
            case LOGIN:
                mView = new LoginView();
                break;
            case REGISTER:
                mView = new RegisterView();
                break;
            case EXITS:
                mView = null;
                break;
            default:
                break;

        }
        return mView;
    }
}
